package com.terrace.db.quartz.mapper.entity;

import java.io.Serializable;
import java.util.Date;

import com.terrace.core.utils.enums.RegexType;
import com.terrace.core.utils.validation.annotation.FieldValid;

/**
 * 任务调度器
 * 
 * @author jiangyg
 *
 */
public class SchedulerJob implements Serializable {

	private static final long serialVersionUID = 7964950656800406475L;

	/**
	 * 计划名称
	 */
	private String schedName;

	/**
	 * 作业名称
	 */
	private String jobName;

	/**
	 * 作业组
	 */
	private String jobGroup;

	/**
	 * 作业类
	 */
	private String jobClazz;

	/**
	 * 作业描述
	 */
	private String jobDescription;

	/**
	 * cronExpression表达式
	 */
	private String cronExpression;

	/**
	 * 触发器状态
	 */
	private String triggerState;

	/**
	 * 前一次执行时间
	 */
	private Date prevFireTime;

	/**
	 * 下次执行时间
	 */
	private Date nextFireTime;

	/**
	 * 失败次数
	 */
	private Integer misFireInstr;

	@FieldValid(depict = "计划名称", regexType = RegexType.CHARACTER)
	public String getSchedName() {
		return schedName;
	}

	public void setSchedName(String schedName) {
		this.schedName = schedName;
	}

	@FieldValid(depict = "作业名称", nullable = false, regexType = RegexType.CHARACTER)
	public String getJobName() {
		return jobName;
	}

	public void setJobName(String jobName) {
		this.jobName = jobName;
	}

	@FieldValid(depict = "作业组", nullable = false, regexType = RegexType.CHARACTER)
	public String getJobGroup() {
		return jobGroup;
	}

	public void setJobGroup(String jobGroup) {
		this.jobGroup = jobGroup;
	}

	@FieldValid(depict = "作业执行类", nullable = false)
	public String getJobClazz() {
		return jobClazz;
	}

	public void setJobClazz(String jobClazz) {
		this.jobClazz = jobClazz;
	}

	public String getJobDescription() {
		return jobDescription;
	}

	public void setJobDescription(String jobDescription) {
		this.jobDescription = jobDescription;
	}

	@FieldValid(depict = "时间表达式", nullable = false)
	public String getCronExpression() {
		return cronExpression;
	}

	public void setCronExpression(String cronExpression) {
		this.cronExpression = cronExpression;
	}

	public String getTriggerState() {
		return triggerState;
	}

	public void setTriggerState(String triggerState) {
		this.triggerState = triggerState;
	}

	public Date getPrevFireTime() {
		return prevFireTime;
	}

	public void setPrevFireTime(Date prevFireTime) {
		this.prevFireTime = prevFireTime;
	}

	public Date getNextFireTime() {
		return nextFireTime;
	}

	public void setNextFireTime(Date nextFireTime) {
		this.nextFireTime = nextFireTime;
	}

	public Integer getMisFireInstr() {
		return misFireInstr;
	}

	public void setMisFireInstr(Integer misFireInstr) {
		this.misFireInstr = misFireInstr;
	}

}
